home *** CD-ROM | disk | FTP | other *** search
/ PC World 2000 February / PCWorld_2000-02_cd.bin / Software / Vyzkuste / xsetup / _SETUP.2 / Group3 / XQ Control Panel Hide 11.xpl < prev    next >
Text File  |  1999-09-16  |  3KB  |  112 lines

  1. "FILE"="Xteq Systems X-Setup Plugin 3.1"
  2. "TYPE"="6"
  3. "COUNT"="3"
  4. "UIPATH"="Appearance\Control Panel\OEM Icons"
  5. "NAME"="Visible OEM Items #5"
  6. "VERSION"="1.32"
  7. "LANGUAGE"="VBScript"
  8. "TEXT 1"="Display "QuickTime" applet [16-bit, 2.x]"
  9. "TEXT 2"="Display "QuickTime" applet [32-bit, 2.x]"
  10. "TEXT 3"="Display "QuickTime" applet [3.x and 4.x]"
  11. "DESCRIPTION 1"="This plug-in can be used to hide or show the different applets inside Start -> Settings -> Control Panel."
  12. "DESCRIPTION 2"="QuickTime plays Apple QuickTime movies and Macintosh .PIC image files on IBM compatibles [Windows machines]."
  13. "DESCRIPTION 3"="It can be downloaded for free from http://www.apple.com/quicktime/."
  14. "AUTHOR"="Xteq Systems"
  15. "COPYRIGHT"="Copyright ⌐ Xteq Systems - All Rights Reserved"
  16. "COMMENT 1"="For more information, go to http://www.xteq.com or write to TeXHeX@gmx.net."
  17. "COMMENT 2"="Thanks to CptSiskoX for the QuickTime Control Panel icon plug-ins."
  18.  
  19. '******************************************************************
  20. '***                COPY !!!! ONLY EDIT LINES BELOW!!!!        ****
  21. '******************************************************************
  22. sVals=""
  23. sVals2=Array("qtw16.cpl","qtw32.cpl","QuickTime.cpl")
  24. sVals3=Array("qtw16.cpl")
  25. '******************************************************************
  26. '*** Keep an eye on the order (must be the same as "TEXT x") ! ****
  27. '******************************************************************
  28. sPath="HKCU\Control Panel\Don't Load\"
  29. sFile="CONTROL.INI"
  30. sFileSec="Don't Load"
  31.  
  32.  
  33.  
  34. SUB Plugin_Initialize
  35.  if GetWinVer=4 then
  36.     sVals=sVals3
  37.  else
  38.     sVals=sVals2
  39.  end if
  40.  
  41.  for i=0 to UBound(sVals)
  42.      Call ReadIt(i+1,sVals(i)) 
  43.  next 
  44. END SUB
  45.  
  46. Sub ReadIt(ITM,VAL)
  47.   If GetWinVer=2 or GetWinVer=4 then
  48.  
  49.      s=RegReadValue(sPath & VAL)
  50.      if IsEmpty(s)=true then
  51.         Call SetUIElement(ITM,true)
  52.      else
  53.         Call SetUIElement(ITM,false)
  54.      end if
  55.  
  56.   else
  57.  
  58.     s=IniReadValue(sFile,sFileSec,VAL)
  59.     if len(s)>0 then
  60.        Call SetUIElement(ITM,false)
  61.     else
  62.        Call SetUIElement(ITM,true)
  63.     end if
  64.      
  65.   end if
  66.      
  67. End Sub
  68.  
  69. 'Called when the Plugin should validate the Data the user has entered
  70. SUB Plugin_CheckData(ElementIndex)
  71. END SUB
  72.  
  73. 'Called when the Plugin should apply the changes
  74. SUB Plugin_Apply(ElementIndex,ElementSubIndex)
  75.  for i=0 to UBound(sVals)
  76.      Call WriteIt(i+1,sVals(i)) 
  77.  next 
  78. END SUB
  79.  
  80. Sub WriteIt(ITM,VAL)
  81.  b=GetUIElement(ITM)
  82.  if b=true then
  83.     'Display it
  84.  
  85.     if GetWinVer=2 or GetWinVer=4 then  
  86.        s=RegReadValue(sPath & VAL)
  87.        if IsEmpty(s)=false then
  88.           Call RegDeleteValue(sPath & VAL)
  89.        end if
  90.     else
  91.        Call IniWriteValue(sFile,sFileSec,VAL,"")
  92.     end if
  93.  
  94.  else
  95.    'Hide it
  96.    
  97.    if GetWinVer=2 or GetWinVer=4 then
  98.       Call RegWriteValue(sPath & VAL,"1",1) 
  99.    else
  100.       Call IniWriteValue(sFile,sFileSec,VAL,"no")
  101.    end if
  102.  
  103.  end if   
  104. End Sub
  105.  
  106.  
  107. 'Called when the Plugin is about to be removed from memory
  108. SUB Plugin_Terminate
  109. END SUB
  110.  
  111.  
  112.